import request from '@/utils/request'

//  查询保单列表
export function queryOrderBase(params) {
  return request({
    url: '/business/insuranceOrder/orderManager/queryOrderBaseList',
    method: 'get',
    params
  })
}

// 导出保单
export function exportOrderBase(params) {
  return request({
    url: '/insuranceOrder/orderManager/exportOrderBase',
    method: 'get',
    params
  })
}

//  导入数据 -- 受灾数据
export function importDisasterData(params) {
  return request({
    url: '/business/insuranceOrder/disaster/importDataAsync',
    method: 'get',
    params
  })
}

//  获取导入数据 -- 理赔数据
export function getClaimSettlementImportData(params) {
  return request({
    url: '/business/insuranceOrder/orderClaim/getBxgsImportData',
    method: 'get',
    params
  })
}

//  导入数据 -- 理赔数据
export function importClaimSettlementData(data) {
  return request({
    url: '/business/insuranceOrder/orderClaim/importBxgsClaimDataAsync',
    method: 'post',
    data
  })
}

//  获取导入数据 -- 抽查数据
export function getSpotCheckImportData(params) {
  return request({
    url: '/business/insuranceOrder/orderClaim/getNyjImportData',
    method: 'get',
    params
  })
}

//  导入数据 -- 抽查数据
export function importSpotCheckData(data) {
  return request({
    url: '/business/insuranceOrder/orderClaim/importNyjClaimDataAsync',
    method: 'post',
    data
  })
}


//  获取导入数据 -- 保单列表
export function getImportData(params) {
  return request({
    url: '/business/insuranceOrder/orderManager/getImportData',
    method: 'get',
    params
  })
}

//  导入数据 -- 保单列表
export function importData(data) {
  return request({
    url: '/business/insuranceOrder/orderManager/importDataAsync',
    method: 'post',
    data
  })
}

//  获取导入数据 -- 保单详情
export function getImportDataDetail(params) {
  return request({
    url: '/business/insuranceOrder/orderDetailManager/getImportData',
    method: 'get',
    params
  })
}

//  导入数据 -- 保单详情
export function importDataDetail(data) {
  return request({
    url: '/business/insuranceOrder/orderDetailManager/importDataAsync',
    method: 'post',
    data
  })
}

//  导入数据 -- 保单详情
export function importGisData(params) {
  return request({
    url: '/business/insuranceOrder/orderManager/importGisData',
    method: 'get',
    params
  })
}




//  获取gis响应数据
export function getGisRepData(params) {
  return request({
    url: '/business/insuranceOrder/orderManager/getGisRepData',
    method: 'get',
    params
  })
}


//  获取gis请求数据
export function getGisReqData(params) {
  return request({
    url: '/business/insuranceOrder/orderManager/getGisReqData',
    method: 'get',
    params
  })
}


//  预览gis上传请求数据
export function previewGisReq(params) {
  return request({
    url: '/business/insuranceOrder/orderManager/previewGisReq',
    method: 'get',
    params
  })
}


//  上传gis数据
export function updateGisData(params) {
  return request({
    url: '/business/insuranceOrder/orderManager/updateGisData',
    method: 'get',
    params
  })
}


//  获取保单详情
export function getOrderBaseVo(params) {
  return request({
    url: `/business/insuranceOrder/orderManager/getOrderBaseDetail`,
    method: 'get',
    params
  })
}

//  获取保单明细的列表
export function queryOrderDetailsById(params) {
  return request({
    url: `/business/insuranceOrder/orderDetailManager/queryOrderDetailList`,
    method: 'get',
    params
  })
}

//  获取保单明细的列表
export function queryOrderDetailListNoGis(params) {
  return request({
    url: `/business/insuranceOrder/orderDetailManager/queryOrderDetailListNoGis`,
    method: 'get',
    params
  })
}

//  获取受灾明细
export function getOrderDisasterDataNoGis(params) {
  return request({
    url: `/business/insuranceOrder/disaster/getOrderDisasterDataNoGis`,
    method: 'get',
    params
  })
}

//  获取受灾详情
export function getOrderDisasterData(params) {
  return request({
    url: `/business/insuranceOrder/disaster/getOrderDisasterData`,
    method: 'get',
    params
  })
}

//  获取理赔明细
export function queryClaimData(params) {
  return request({
    url: `/business/insuranceOrder/orderClaim/queryClaimData`,
    method: 'get',
    params
  })
}


//  获取抽查明细
export function queryClaimDataForCc(params) {
  return request({
    url: `/business/insuranceOrder/orderClaim/queryClaimDataForCc`,
    method: 'get',
    params
  })
}


//  新增保单
export function addOrder(data) {
  return request({
    url: '/business/insuranceOrder/orderManager/addOrder',
    method: 'post',
    data
  })
}

//  更新保单
export function updateOrder(data) {
  return request({
    url: '/business/insuranceOrder/orderManager/updateOrder',
    method: 'put',
    data
  })
}

//  删除保单
export function deleteOrder(params) {
  return request({
    url: `/business/insuranceOrder/orderManager/deleteOrderBase`,
    method: 'delete',
    params
  })
}

//  获取抽查明细
export function archivist(id) {
  return request({
    url: `/business/insuranceOrder/orderManager/archivist/${id}`,
    method: 'get',

  })
}

//  计算理赔金额
export function computeBF(id) {
  return request({
    url: `/business/insuranceOrder/orderManager/computeBF/${id}`,
    method: 'get',

  })
}


